<!DOCTYPE composition PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<ui:composition xmlns="http://www.w3.org/1999/xhtml"
                xmlns:ui="http://java.sun.com/jsf/facelets"
                xmlns:h="http://java.sun.com/jsf/html"
                xmlns:f="http://java.sun.com/jsf/core"
                xmlns:s="http://jboss.com/products/seam/taglib"
                xmlns:a="http://richfaces.org/a4j"
                template="template.xhtml">

    <!-- content -->
    <ui:define name="content">
        <h:form>

            <div class="section">
                <h2><a name="backToTop">#{messages['hotel_view_label']}</a></h2>
                <div class="messages"><h:messages infoClass="successBox"
                                                  warnClass="infoBox" errorClass="warningBox" fatalClass="errorBox"
                                                  globalOnly="true" showDetail="false" showSummary="true" />
                </div>
                <br/>
                <table class="bodyTable detailPages">
                    <thead>
                        <tr>
                            <th class="field">#{messages['hotel_view_field_label']}</th>
                            <th class="value">#{messages['hotel_view_value_label']}</th>
                        </tr>
                    </thead>
                    <tbody>
                        <tr class="a">
                            <td class="field">#{messages['hotel_name_label']}</td>
                            <td class="value">#{hotelViewPage.hotel.name}</td>
                        </tr>
                        <tr class="a">
                            <td class="field">#{messages['hotel_address_label']}</td>
                            <td class="value">#{hotelViewPage.hotel.address}</td>
                        </tr>
                        <tr class="a">
                            <td class="field">#{messages['hotel_zip_label']}</td>
                            <td class="value">#{hotelViewPage.hotel.zip}</td>
                        </tr>
                        <tr class="a">
                            <td class="field">#{messages['hotel_city_label']}</td>
                            <td class="value">#{hotelViewPage.hotel.city}</td>
                        </tr>
                        <tr class="a">
                            <td class="field">#{messages['hotel_country_label']}</td>
                            <td class="value">#{hotelViewPage.hotel.country}</td>
                        </tr>
                        <tr class="a">
                            <td class="field">#{messages['hotel_price_label']}</td>
                            <td class="value">#{hotelViewPage.hotel.price}</td>
                        </tr>
                    </tbody>
                </table>
                <br />
                <p>&#160;
                    <a:commandLink action="#{hotelEditPage.show(hotelViewPage.hotel.id)}"
                                    status="gstat"
                                    eventsQueue="hotelEditAction" ignoreDupResponses="true"
                                    value="#{messages['hotel_action_edit']}" >
                    </a:commandLink>
                    <h:outputText value=" | " />
                    <a:commandLink action="#{hotelViewPage.showHotelList}"
                                   status="gstat" eventsQueue="mainPage" ignoreDupResponses="true" immediate="true">
                        <h:outputFormat value="#{messages['hotel_view_back_to_list']}"></h:outputFormat>
                    </a:commandLink>
                </p>
            </div>
        </h:form>
    </ui:define>
</ui:composition>